<?php
namespace removeData\lib;

use removeData\lib\Rconfig;

abstract class Engine{
	public $engine ;
	public function __construct(){
		if(empty(Rconfig::$config)){
			$this->loadConfig();
		}
		$engine_name = ucfirst(Rconfig::$config['engine']);
		$class = "\\removeData\\engine\\$engine_name";
		$this->engine = new $class();
	}
	/**
	* 导入数据的总数 
	**/
	abstract function count();

	abstract function data($i);

	abstract function hookAfterProcess();

	protected function loadConfig(){
		Rconfig::$config = require(dirname(__DIR__) . '/config.php');
	}
}